package com.qudian.pay.mq;

import java.io.Serializable;
import java.util.Map;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.alibaba.rocketmq.common.message.MessageExt;

/**
 * @Description: 从MQ接收的消息,未直接使用MessageExt-便于以后扩展(比如产品上下文信息,业务流水信息)
 * @author gaoxiang
 * @date 2016年5月23日 下午1:19:43
 */
public class ReceiveMessage extends MessageExt implements Serializable {
	
	private static final long serialVersionUID = -2397884125297224005L;
	
	/**
	 * @Fields instanceName : producer的实例名
	 */ 
	private String instanceName;
	
	private Map<String, Object> bizValue;
	
	public Map<String, Object> getBizValue() {
		return bizValue;
	}
	
	public void setBizValue(Map<String, Object> bizValue) {
		this.bizValue = bizValue;
	}
	
	public String getInstanceName() {
		return instanceName;
	}
	
	public void setInstanceName(String instanceName) {
		this.instanceName = instanceName;
	}
	
	public String toString() {
		try {
			return ToStringBuilder.reflectionToString(this, ToStringStyle.SHORT_PREFIX_STYLE);
		} catch (Exception e) {
			return super.toString();
		}
	}
}
